package com.jifeng.br.pjj.bookreader.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 图书评论表
 *
 * @author Kakarot
 * @email ${email}
 * @date 2023-07-11 10:57:23
 */
@Data
@TableName(value = "br_book_comment", resultMap = "commentMap")
public class BookCommentEntity implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 * 主键自增
	 */
	@TableId(type = IdType.AUTO)
	private Integer id;
	/**
	 * 评论人编号
	 */
	private Integer userId;
	/**
	 * 评论内容
	 */
	private String content;
	/**
	 * 评论时间
	 */
	private Date commentTime;
	/**
	 * 图书编号
	 */
	private Integer bookId;
	/**
	 * 状态1可用2禁用,默认1
	 */
	private Integer status;
	/**
	 * 创建时间
	 */
	@TableField(value = "create_time", fill = FieldFill.INSERT)
	private Date createTime;
	/**
	 * 创建人
	 */
	@TableField(value = "create_user", fill = FieldFill.INSERT)
	private Integer createUser;
	/**
	 * 最后一次修改时间
	 */
	@TableField(value = "update_time", fill = FieldFill.UPDATE)
	private Date updateTime;
	/**
	 * 最后一次修改人
	 */
	@TableField(value = "update_user", fill = FieldFill.UPDATE)
	private Integer updateUser;

	@TableField(exist = false)
	private Double score;
	@TableField(exist = false)
	private BookEntity book;
	@TableField(exist = false)
	private VipEntity vip;
}
